// Copyright 2025 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Code generated by sidekick. DO NOT EDIT.

pub mod gke_inference_quickstart {
    use crate::Result;

    /// A builder for [GkeInferenceQuickstart][crate::client::GkeInferenceQuickstart].
    ///
    /// ```
    /// # tokio_test::block_on(async {
    /// # use google_cloud_gkerecommender_v1::*;
    /// # use builder::gke_inference_quickstart::ClientBuilder;
    /// # use client::GkeInferenceQuickstart;
    /// let builder : ClientBuilder = GkeInferenceQuickstart::builder();
    /// let client = builder
    ///     .with_endpoint("https://gkerecommender.googleapis.com")
    ///     .build().await?;
    /// # gax::client_builder::Result::<()>::Ok(()) });
    /// ```
    pub type ClientBuilder =
        gax::client_builder::ClientBuilder<client::Factory, gaxi::options::Credentials>;

    pub(crate) mod client {
        use super::super::super::client::GkeInferenceQuickstart;
        pub struct Factory;
        impl gax::client_builder::internal::ClientFactory for Factory {
            type Client = GkeInferenceQuickstart;
            type Credentials = gaxi::options::Credentials;
            async fn build(
                self,
                config: gaxi::options::ClientConfig,
            ) -> gax::client_builder::Result<Self::Client> {
                Self::Client::new(config).await
            }
        }
    }

    /// Common implementation for [crate::client::GkeInferenceQuickstart] request builders.
    #[derive(Clone, Debug)]
    pub(crate) struct RequestBuilder<R: std::default::Default> {
        stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        request: R,
        options: gax::options::RequestOptions,
    }

    impl<R> RequestBuilder<R>
    where
        R: std::default::Default,
    {
        pub(crate) fn new(
            stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        ) -> Self {
            Self {
                stub,
                request: R::default(),
                options: gax::options::RequestOptions::default(),
            }
        }
    }

    /// The request builder for [GkeInferenceQuickstart::fetch_models][crate::client::GkeInferenceQuickstart::fetch_models] calls.
    ///
    /// # Example
    /// ```no_run
    /// # use google_cloud_gkerecommender_v1::builder;
    /// use builder::gke_inference_quickstart::FetchModels;
    /// # tokio_test::block_on(async {
    ///
    /// let builder = prepare_request_builder();
    /// let response = builder.send().await?;
    /// # gax::Result::<()>::Ok(()) });
    ///
    /// fn prepare_request_builder() -> FetchModels {
    ///   # panic!();
    ///   // ... details omitted ...
    /// }
    /// ```
    #[derive(Clone, Debug)]
    pub struct FetchModels(RequestBuilder<crate::model::FetchModelsRequest>);

    impl FetchModels {
        pub(crate) fn new(
            stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        ) -> Self {
            Self(RequestBuilder::new(stub))
        }

        /// Sets the full request, replacing any prior values.
        pub fn with_request<V: Into<crate::model::FetchModelsRequest>>(mut self, v: V) -> Self {
            self.0.request = v.into();
            self
        }

        /// Sets all the options, replacing any prior values.
        pub fn with_options<V: Into<gax::options::RequestOptions>>(mut self, v: V) -> Self {
            self.0.options = v.into();
            self
        }

        /// Sends the request.
        pub async fn send(self) -> Result<crate::model::FetchModelsResponse> {
            (*self.0.stub)
                .fetch_models(self.0.request, self.0.options)
                .await
                .map(gax::response::Response::into_body)
        }

        /// Sets the value of [page_size][crate::model::FetchModelsRequest::page_size].
        pub fn set_page_size<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_size][crate::model::FetchModelsRequest::page_size].
        pub fn set_or_clear_page_size<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = v.map(|x| x.into());
            self
        }

        /// Sets the value of [page_token][crate::model::FetchModelsRequest::page_token].
        pub fn set_page_token<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_token][crate::model::FetchModelsRequest::page_token].
        pub fn set_or_clear_page_token<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = v.map(|x| x.into());
            self
        }
    }

    #[doc(hidden)]
    impl gax::options::internal::RequestBuilder for FetchModels {
        fn request_options(&mut self) -> &mut gax::options::RequestOptions {
            &mut self.0.options
        }
    }

    /// The request builder for [GkeInferenceQuickstart::fetch_model_servers][crate::client::GkeInferenceQuickstart::fetch_model_servers] calls.
    ///
    /// # Example
    /// ```no_run
    /// # use google_cloud_gkerecommender_v1::builder;
    /// use builder::gke_inference_quickstart::FetchModelServers;
    /// # tokio_test::block_on(async {
    ///
    /// let builder = prepare_request_builder();
    /// let response = builder.send().await?;
    /// # gax::Result::<()>::Ok(()) });
    ///
    /// fn prepare_request_builder() -> FetchModelServers {
    ///   # panic!();
    ///   // ... details omitted ...
    /// }
    /// ```
    #[derive(Clone, Debug)]
    pub struct FetchModelServers(RequestBuilder<crate::model::FetchModelServersRequest>);

    impl FetchModelServers {
        pub(crate) fn new(
            stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        ) -> Self {
            Self(RequestBuilder::new(stub))
        }

        /// Sets the full request, replacing any prior values.
        pub fn with_request<V: Into<crate::model::FetchModelServersRequest>>(
            mut self,
            v: V,
        ) -> Self {
            self.0.request = v.into();
            self
        }

        /// Sets all the options, replacing any prior values.
        pub fn with_options<V: Into<gax::options::RequestOptions>>(mut self, v: V) -> Self {
            self.0.options = v.into();
            self
        }

        /// Sends the request.
        pub async fn send(self) -> Result<crate::model::FetchModelServersResponse> {
            (*self.0.stub)
                .fetch_model_servers(self.0.request, self.0.options)
                .await
                .map(gax::response::Response::into_body)
        }

        /// Sets the value of [model][crate::model::FetchModelServersRequest::model].
        ///
        /// This is a **required** field for requests.
        pub fn set_model<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.model = v.into();
            self
        }

        /// Sets the value of [page_size][crate::model::FetchModelServersRequest::page_size].
        pub fn set_page_size<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_size][crate::model::FetchModelServersRequest::page_size].
        pub fn set_or_clear_page_size<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = v.map(|x| x.into());
            self
        }

        /// Sets the value of [page_token][crate::model::FetchModelServersRequest::page_token].
        pub fn set_page_token<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_token][crate::model::FetchModelServersRequest::page_token].
        pub fn set_or_clear_page_token<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = v.map(|x| x.into());
            self
        }
    }

    #[doc(hidden)]
    impl gax::options::internal::RequestBuilder for FetchModelServers {
        fn request_options(&mut self) -> &mut gax::options::RequestOptions {
            &mut self.0.options
        }
    }

    /// The request builder for [GkeInferenceQuickstart::fetch_model_server_versions][crate::client::GkeInferenceQuickstart::fetch_model_server_versions] calls.
    ///
    /// # Example
    /// ```no_run
    /// # use google_cloud_gkerecommender_v1::builder;
    /// use builder::gke_inference_quickstart::FetchModelServerVersions;
    /// # tokio_test::block_on(async {
    ///
    /// let builder = prepare_request_builder();
    /// let response = builder.send().await?;
    /// # gax::Result::<()>::Ok(()) });
    ///
    /// fn prepare_request_builder() -> FetchModelServerVersions {
    ///   # panic!();
    ///   // ... details omitted ...
    /// }
    /// ```
    #[derive(Clone, Debug)]
    pub struct FetchModelServerVersions(
        RequestBuilder<crate::model::FetchModelServerVersionsRequest>,
    );

    impl FetchModelServerVersions {
        pub(crate) fn new(
            stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        ) -> Self {
            Self(RequestBuilder::new(stub))
        }

        /// Sets the full request, replacing any prior values.
        pub fn with_request<V: Into<crate::model::FetchModelServerVersionsRequest>>(
            mut self,
            v: V,
        ) -> Self {
            self.0.request = v.into();
            self
        }

        /// Sets all the options, replacing any prior values.
        pub fn with_options<V: Into<gax::options::RequestOptions>>(mut self, v: V) -> Self {
            self.0.options = v.into();
            self
        }

        /// Sends the request.
        pub async fn send(self) -> Result<crate::model::FetchModelServerVersionsResponse> {
            (*self.0.stub)
                .fetch_model_server_versions(self.0.request, self.0.options)
                .await
                .map(gax::response::Response::into_body)
        }

        /// Sets the value of [model][crate::model::FetchModelServerVersionsRequest::model].
        ///
        /// This is a **required** field for requests.
        pub fn set_model<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.model = v.into();
            self
        }

        /// Sets the value of [model_server][crate::model::FetchModelServerVersionsRequest::model_server].
        ///
        /// This is a **required** field for requests.
        pub fn set_model_server<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.model_server = v.into();
            self
        }

        /// Sets the value of [page_size][crate::model::FetchModelServerVersionsRequest::page_size].
        pub fn set_page_size<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_size][crate::model::FetchModelServerVersionsRequest::page_size].
        pub fn set_or_clear_page_size<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = v.map(|x| x.into());
            self
        }

        /// Sets the value of [page_token][crate::model::FetchModelServerVersionsRequest::page_token].
        pub fn set_page_token<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_token][crate::model::FetchModelServerVersionsRequest::page_token].
        pub fn set_or_clear_page_token<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = v.map(|x| x.into());
            self
        }
    }

    #[doc(hidden)]
    impl gax::options::internal::RequestBuilder for FetchModelServerVersions {
        fn request_options(&mut self) -> &mut gax::options::RequestOptions {
            &mut self.0.options
        }
    }

    /// The request builder for [GkeInferenceQuickstart::fetch_profiles][crate::client::GkeInferenceQuickstart::fetch_profiles] calls.
    ///
    /// # Example
    /// ```no_run
    /// # use google_cloud_gkerecommender_v1::builder;
    /// use builder::gke_inference_quickstart::FetchProfiles;
    /// # tokio_test::block_on(async {
    /// use gax::paginator::ItemPaginator;
    ///
    /// let builder = prepare_request_builder();
    /// let mut items = builder.by_item();
    /// while let Some(result) = items.next().await {
    ///   let item = result?;
    /// }
    /// # gax::Result::<()>::Ok(()) });
    ///
    /// fn prepare_request_builder() -> FetchProfiles {
    ///   # panic!();
    ///   // ... details omitted ...
    /// }
    /// ```
    #[derive(Clone, Debug)]
    pub struct FetchProfiles(RequestBuilder<crate::model::FetchProfilesRequest>);

    impl FetchProfiles {
        pub(crate) fn new(
            stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        ) -> Self {
            Self(RequestBuilder::new(stub))
        }

        /// Sets the full request, replacing any prior values.
        pub fn with_request<V: Into<crate::model::FetchProfilesRequest>>(mut self, v: V) -> Self {
            self.0.request = v.into();
            self
        }

        /// Sets all the options, replacing any prior values.
        pub fn with_options<V: Into<gax::options::RequestOptions>>(mut self, v: V) -> Self {
            self.0.options = v.into();
            self
        }

        /// Sends the request.
        pub async fn send(self) -> Result<crate::model::FetchProfilesResponse> {
            (*self.0.stub)
                .fetch_profiles(self.0.request, self.0.options)
                .await
                .map(gax::response::Response::into_body)
        }

        /// Streams each page in the collection.
        pub fn by_page(
            self,
        ) -> impl gax::paginator::Paginator<crate::model::FetchProfilesResponse, gax::error::Error>
        {
            use std::clone::Clone;
            let token = self.0.request.page_token.clone().unwrap_or_default();
            let execute = move |token: String| {
                let mut builder = self.clone();
                builder.0.request = builder.0.request.set_page_token(token);
                builder.send()
            };
            gax::paginator::internal::new_paginator(token, execute)
        }

        /// Streams each item in the collection.
        pub fn by_item(
            self,
        ) -> impl gax::paginator::ItemPaginator<crate::model::FetchProfilesResponse, gax::error::Error>
        {
            use gax::paginator::Paginator;
            self.by_page().items()
        }

        /// Sets the value of [model][crate::model::FetchProfilesRequest::model].
        pub fn set_model<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.model = v.into();
            self
        }

        /// Sets the value of [model_server][crate::model::FetchProfilesRequest::model_server].
        pub fn set_model_server<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.model_server = v.into();
            self
        }

        /// Sets the value of [model_server_version][crate::model::FetchProfilesRequest::model_server_version].
        pub fn set_model_server_version<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.model_server_version = v.into();
            self
        }

        /// Sets the value of [performance_requirements][crate::model::FetchProfilesRequest::performance_requirements].
        pub fn set_performance_requirements<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<crate::model::PerformanceRequirements>,
        {
            self.0.request.performance_requirements = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [performance_requirements][crate::model::FetchProfilesRequest::performance_requirements].
        pub fn set_or_clear_performance_requirements<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<crate::model::PerformanceRequirements>,
        {
            self.0.request.performance_requirements = v.map(|x| x.into());
            self
        }

        /// Sets the value of [page_size][crate::model::FetchProfilesRequest::page_size].
        pub fn set_page_size<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_size][crate::model::FetchProfilesRequest::page_size].
        pub fn set_or_clear_page_size<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<i32>,
        {
            self.0.request.page_size = v.map(|x| x.into());
            self
        }

        /// Sets the value of [page_token][crate::model::FetchProfilesRequest::page_token].
        pub fn set_page_token<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [page_token][crate::model::FetchProfilesRequest::page_token].
        pub fn set_or_clear_page_token<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<std::string::String>,
        {
            self.0.request.page_token = v.map(|x| x.into());
            self
        }
    }

    #[doc(hidden)]
    impl gax::options::internal::RequestBuilder for FetchProfiles {
        fn request_options(&mut self) -> &mut gax::options::RequestOptions {
            &mut self.0.options
        }
    }

    /// The request builder for [GkeInferenceQuickstart::generate_optimized_manifest][crate::client::GkeInferenceQuickstart::generate_optimized_manifest] calls.
    ///
    /// # Example
    /// ```no_run
    /// # use google_cloud_gkerecommender_v1::builder;
    /// use builder::gke_inference_quickstart::GenerateOptimizedManifest;
    /// # tokio_test::block_on(async {
    ///
    /// let builder = prepare_request_builder();
    /// let response = builder.send().await?;
    /// # gax::Result::<()>::Ok(()) });
    ///
    /// fn prepare_request_builder() -> GenerateOptimizedManifest {
    ///   # panic!();
    ///   // ... details omitted ...
    /// }
    /// ```
    #[derive(Clone, Debug)]
    pub struct GenerateOptimizedManifest(
        RequestBuilder<crate::model::GenerateOptimizedManifestRequest>,
    );

    impl GenerateOptimizedManifest {
        pub(crate) fn new(
            stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        ) -> Self {
            Self(RequestBuilder::new(stub))
        }

        /// Sets the full request, replacing any prior values.
        pub fn with_request<V: Into<crate::model::GenerateOptimizedManifestRequest>>(
            mut self,
            v: V,
        ) -> Self {
            self.0.request = v.into();
            self
        }

        /// Sets all the options, replacing any prior values.
        pub fn with_options<V: Into<gax::options::RequestOptions>>(mut self, v: V) -> Self {
            self.0.options = v.into();
            self
        }

        /// Sends the request.
        pub async fn send(self) -> Result<crate::model::GenerateOptimizedManifestResponse> {
            (*self.0.stub)
                .generate_optimized_manifest(self.0.request, self.0.options)
                .await
                .map(gax::response::Response::into_body)
        }

        /// Sets the value of [model_server_info][crate::model::GenerateOptimizedManifestRequest::model_server_info].
        ///
        /// This is a **required** field for requests.
        pub fn set_model_server_info<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<crate::model::ModelServerInfo>,
        {
            self.0.request.model_server_info = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [model_server_info][crate::model::GenerateOptimizedManifestRequest::model_server_info].
        ///
        /// This is a **required** field for requests.
        pub fn set_or_clear_model_server_info<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<crate::model::ModelServerInfo>,
        {
            self.0.request.model_server_info = v.map(|x| x.into());
            self
        }

        /// Sets the value of [accelerator_type][crate::model::GenerateOptimizedManifestRequest::accelerator_type].
        ///
        /// This is a **required** field for requests.
        pub fn set_accelerator_type<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.accelerator_type = v.into();
            self
        }

        /// Sets the value of [kubernetes_namespace][crate::model::GenerateOptimizedManifestRequest::kubernetes_namespace].
        pub fn set_kubernetes_namespace<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.kubernetes_namespace = v.into();
            self
        }

        /// Sets the value of [performance_requirements][crate::model::GenerateOptimizedManifestRequest::performance_requirements].
        pub fn set_performance_requirements<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<crate::model::PerformanceRequirements>,
        {
            self.0.request.performance_requirements = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [performance_requirements][crate::model::GenerateOptimizedManifestRequest::performance_requirements].
        pub fn set_or_clear_performance_requirements<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<crate::model::PerformanceRequirements>,
        {
            self.0.request.performance_requirements = v.map(|x| x.into());
            self
        }

        /// Sets the value of [storage_config][crate::model::GenerateOptimizedManifestRequest::storage_config].
        pub fn set_storage_config<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<crate::model::StorageConfig>,
        {
            self.0.request.storage_config = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [storage_config][crate::model::GenerateOptimizedManifestRequest::storage_config].
        pub fn set_or_clear_storage_config<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<crate::model::StorageConfig>,
        {
            self.0.request.storage_config = v.map(|x| x.into());
            self
        }
    }

    #[doc(hidden)]
    impl gax::options::internal::RequestBuilder for GenerateOptimizedManifest {
        fn request_options(&mut self) -> &mut gax::options::RequestOptions {
            &mut self.0.options
        }
    }

    /// The request builder for [GkeInferenceQuickstart::fetch_benchmarking_data][crate::client::GkeInferenceQuickstart::fetch_benchmarking_data] calls.
    ///
    /// # Example
    /// ```no_run
    /// # use google_cloud_gkerecommender_v1::builder;
    /// use builder::gke_inference_quickstart::FetchBenchmarkingData;
    /// # tokio_test::block_on(async {
    ///
    /// let builder = prepare_request_builder();
    /// let response = builder.send().await?;
    /// # gax::Result::<()>::Ok(()) });
    ///
    /// fn prepare_request_builder() -> FetchBenchmarkingData {
    ///   # panic!();
    ///   // ... details omitted ...
    /// }
    /// ```
    #[derive(Clone, Debug)]
    pub struct FetchBenchmarkingData(RequestBuilder<crate::model::FetchBenchmarkingDataRequest>);

    impl FetchBenchmarkingData {
        pub(crate) fn new(
            stub: std::sync::Arc<dyn super::super::stub::dynamic::GkeInferenceQuickstart>,
        ) -> Self {
            Self(RequestBuilder::new(stub))
        }

        /// Sets the full request, replacing any prior values.
        pub fn with_request<V: Into<crate::model::FetchBenchmarkingDataRequest>>(
            mut self,
            v: V,
        ) -> Self {
            self.0.request = v.into();
            self
        }

        /// Sets all the options, replacing any prior values.
        pub fn with_options<V: Into<gax::options::RequestOptions>>(mut self, v: V) -> Self {
            self.0.options = v.into();
            self
        }

        /// Sends the request.
        pub async fn send(self) -> Result<crate::model::FetchBenchmarkingDataResponse> {
            (*self.0.stub)
                .fetch_benchmarking_data(self.0.request, self.0.options)
                .await
                .map(gax::response::Response::into_body)
        }

        /// Sets the value of [model_server_info][crate::model::FetchBenchmarkingDataRequest::model_server_info].
        ///
        /// This is a **required** field for requests.
        pub fn set_model_server_info<T>(mut self, v: T) -> Self
        where
            T: std::convert::Into<crate::model::ModelServerInfo>,
        {
            self.0.request.model_server_info = std::option::Option::Some(v.into());
            self
        }

        /// Sets or clears the value of [model_server_info][crate::model::FetchBenchmarkingDataRequest::model_server_info].
        ///
        /// This is a **required** field for requests.
        pub fn set_or_clear_model_server_info<T>(mut self, v: std::option::Option<T>) -> Self
        where
            T: std::convert::Into<crate::model::ModelServerInfo>,
        {
            self.0.request.model_server_info = v.map(|x| x.into());
            self
        }

        /// Sets the value of [instance_type][crate::model::FetchBenchmarkingDataRequest::instance_type].
        pub fn set_instance_type<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.instance_type = v.into();
            self
        }

        /// Sets the value of [pricing_model][crate::model::FetchBenchmarkingDataRequest::pricing_model].
        pub fn set_pricing_model<T: Into<std::string::String>>(mut self, v: T) -> Self {
            self.0.request.pricing_model = v.into();
            self
        }
    }

    #[doc(hidden)]
    impl gax::options::internal::RequestBuilder for FetchBenchmarkingData {
        fn request_options(&mut self) -> &mut gax::options::RequestOptions {
            &mut self.0.options
        }
    }
}
